import location.LocationServiceImpl;
import location.LocationServiceImplService;
import weather.WeatherServiceImpl;
import weather.WeatherServiceImplService;

/**
 * @author 乐乐
 */
public class ClientRun {
    public static void main(String[] args) {
        System.out.println("开始定位，请耐心等待...");

        LocationServiceImpl locationServiceImpl = new LocationServiceImplService().getLocationServiceImplPort();
        String cityName = locationServiceImpl.getLocationCityName();
        System.out.printf("您的位置是：%s%n", cityName);

        System.out.println("开始查询天气...");

        WeatherServiceImpl weatherServiceImpl = new WeatherServiceImplService().getWeatherServiceImplPort();
        String weather = weatherServiceImpl.getWeatherByCityName("深圳");

        System.out.printf("%s明天的天气是：%s%n", cityName, weather);
    }
}
